<template>
  <div class="registerbox">
    <el-card>
      <el-button class="fr">
        删除
      </el-button>
      <el-button class="fr">
        编辑
      </el-button>
      <h3>维修记录详情</h3>
    </el-card>
    <el-card class="gray-card no-border no-margin-top" shadow="never">
      <el-form ref="form" :model="form" class="form">
        <el-row>
          <el-col :span="12">
            <el-form-item label="仪器编号：">
              <el-input v-model="form.instrumentNo"></el-input>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="所属科室：">
              <el-input v-model="form.instrumentNo"></el-input>
            </el-form-item>
          </el-col>
        </el-row>
        <el-row>
          <el-col :span="12">
            <el-form-item label="仪器名称：">
              <el-input v-model="form.instrumentName"></el-input>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="仪器型号：">
              <el-date-picker
                v-model="form.createTime"
                type="datetime"
                format="yyyy-MM-DD HH:mm:ss"
                placeholder="选择维护时间"
              >
              </el-date-picker>
            </el-form-item>
          </el-col>
        </el-row>
        <el-row>
          <el-col :span="12">
            <el-form-item label="维修时间：">
              <el-input v-model="form.maintainer"></el-input>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="所属厂商：">
              <el-input v-model="form.result"></el-input>
            </el-form-item>
          </el-col>
        </el-row>

        <el-row>
          <el-col :span="12">
            <el-form-item label="维修人：">
              <el-input v-model="form.maintainer"></el-input>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="联系方式：">
              <el-input v-model="form.result"></el-input>
            </el-form-item>
          </el-col>
        </el-row>

        <el-form-item label="维修原因：">
          <el-input type="textarea" class="textarea"
                    :rows="4"
                    placeholder="请输入内容"
                    v-model="form.remark">
          </el-input>
        </el-form-item>

        <el-form-item label="维修结果：">
          <el-input type="textarea" class="textarea"
                    :rows="4"
                    placeholder="请输入内容"
                    v-model="form.remark">
          </el-input>
        </el-form-item>

      </el-form>
    </el-card>
    <div class="details-foot">
      <div class="cell-btn">
        <el-button type="primary" @click.native="handleSubmit">提交</el-button>
        <el-button @click.native="handleClose">取消</el-button>
      </div>
    </div>
  </div>
</template>

<script>


export default {
  name: "maintenanceInfo",
  components:{

  },
  data() {
    return {
      checkList: [],
      loading: false,
      redirect: undefined,
      activeName: '1',
      deviceInfo:{},
      dateOptions: [{
          value: '选项1',
          label: '最近30天'
        }, {
          value: '选项2',
          label: '最近一周'
        }, {
          value: '选项3',
          label: '最近半月'
        }, {
          value: '选项4',
          label: '最近一年'
        }, {
          value: '选项5',
          label: '自定义'
        }],
        value: ''
    };
  },
  watch: {

  },
  created() {
      this.getCheckList()
  },
  methods: {
    getCheckList(){
        let check ={
            checkNo:'JY-0001',
            name:'孙悟空',
            checkName:'血红蛋白',
            checkTime:'2021/02/01 12:00',
            checkResult:'正常',
            isReport:'待生成'
        }
        for(let i=0;i<5;i++){
            this.checkList.push(check)
        }
    },
    toDeviceInfo(id){
        this.$router.push({path:"/device/deviceInfo/index"});
    }
  }
};
</script>
